/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.openjawtech.xscraper.scraper;

import org.w3c.dom.Node;

/**
 *
 * @author Wenbo.Sun
 */
public class Print {

    public static void print(Node node, String indent) {
        System.out.println(indent+node.getClass().getName());
        Node child = node.getFirstChild();
        while (child != null) {
            print(child, indent+" " + child.getNodeValue());
            child = child.getNextSibling();
        }
    }
}
